package io.jt808.interceptor;

import io.norland.dispatcher.SimpleProtoInterceptor;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
public class TestInterceptor {
    @Bean
    public SimpleProtoInterceptor test() {
        return SimpleProtoInterceptor.builder()
                .supportProtoName("8103")
                .preHandle((req) -> {
                    return true;
                })
                .postHandle((req, actionAndModel) -> {
                    System.out.println("hahahwa");
                }).build();
    }
}
